package com.ssm.common.persistence;

import java.util.Date;

/**   
*    
* 项目名称：filmSys   
* 类名称：DataEntity   
* 类描述：   数据Entity类
* 创建人：edwarder   
* 创建时间：2018年6月20日 下午2:41:44   
*       
*/
public class DataEntity<T> extends BaseEntity<T>{

	private static final long serialVersionUID = 1L;
	
	protected Date createDate;	// 创建日期
	protected Date updateDate;	// 更新日期
	protected String delFlag; 	// 删除标记（0：正常；1：删除；2：审核）

	public DataEntity() {
		super();
		this.delFlag = DEL_FLAG_NORMAL;
	}
	
	public DataEntity(Integer id) {
		super(id);
	}
	
	@Override
	public void preInsert() {
		this.updateDate = new Date();
		this.createDate = this.updateDate;
	}

	@Override
	public void preUpdate() {
		this.updateDate = new Date();
	}

	public Date getCreateDate() {
		return createDate;
	}

	public void setCreateDate(Date createDate) {
		this.createDate = createDate;
	}

	public Date getUpdateDate() {
		return updateDate;
	}

	public void setUpdateDate(Date updateDate) {
		this.updateDate = updateDate;
	}

	public String getDelFlag() {
		return delFlag;
	}

	public void setDelFlag(String delFlag) {
		this.delFlag = delFlag;
	}

}
